package com.qf.commerce.mapper;

import com.qf.commerce.common.dto.SeckillActivityDto;
import com.qf.commerce.entity.SeckillActivity;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface SeckillActivityMapper {
    //条件查询加分页 秒杀活动展示
    List<SeckillActivity> selectSeckillActivity(@Param("seckillActivity") SeckillActivity seckillActivity);
    //批量删除 status 0
    int deleteById(@Param("seckillActivityId") List<Long> seckillActivityId);
    //批量启用 status 1
    int updateStatusById(@Param("seckillActivityId") List<Long> seckillActivityId);
    //批量停用
    int updateActivityStatusById(@Param("seckillActivityId")List<Long> seckillActivityId);
    //查询秒杀活动状态
    SeckillActivity selectSeckillActivityById(@Param("seckillActivityId") Long seckillActivityId);
    //修改秒杀活动状态
    int updateActivityById(@Param("seckillActivity")SeckillActivity seckillActivity);
    //添加活动场次
    int insertActivity(@Param("seckillActivityDto")SeckillActivityDto seckillActivityDto);
}
